package com.omuao.message.queue.api;

/**
 * Api结果
 *
 * @author omuao
 */
public class ApiResult {

    public static final ApiResult SUCCESS = new ApiResult("SUCCESS", "Ok!");

    public static final ApiResult FAILED = new ApiResult("FAILED", "Error!");

    private String code;

    private String message;

    public ApiResult() {
    }

    public ApiResult(String code, String message) {
        this.code = code;
        this.message = message;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public static ApiResult success() {
        return SUCCESS;
    }
}
